#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
//#include "ourhdr.h"

#define BUFFSIZE 8192

void err_sys(char * info) {
	fprintf(stderr, "%s\n", info);
	exit(EXIT_FAILURE);
}

int main(int argc, char * aargv[]) {
	int n;
	char buf[BUFFSIZE];

	while((n = read(STDIN_FILENO, buf, BUFFSIZE)) > 0)
		if(write(STDOUT_FILENO, buf, n) != n)
			err_sys("write error");

	if(n < 0)
		err_sys("read error");

	exit(0);
}
